package com.pwc.conversionTool.csvProcess;

import java.io.File;
import java.io.FileReader;
import java.io.IOException;
import java.util.Arrays;
import java.util.List;

import au.com.bytecode.opencsv.CSVReader;

public class imaProcess {
	private File fileName= new File("resources/img");
	public String path = "C:\\Users\\dwu102\\jboss-as-7.0.1.Final\\standalone\\tmp\\tmpFiles";

	public List<String> getTablehead() throws IOException {
		
		
		File[] files = fileName.listFiles();
		
		fileName.getName();
		
		fileName.getPath();
		
		List<String[]> list = null;
		String filepath = path + File.separator + "123.csv";

	    
		
		CSVReader csvreader = null;
		

		csvreader = new CSVReader(new FileReader(filepath));
		list = csvreader.readAll();
		
		csvreader.close();
		if (list != null) {

			List<String> headList = Arrays.asList(list.get(0));
			return headList;

		}

		return null;
}
}
